libxc: provide XENCTRL_HAS_XC_INTERFACE feature test macro
authorIan Jackson <ian.jackson@eu.citrix.com>
Thu, 27 Jan 2011 14:59:04 +0000 (14:59 +0000)
committerIan Jackson <ian.jackson@eu.citrix.com>
Thu, 27 Jan 2011 14:59:04 +0000 (14:59 +0000)
This makes it easier for out-of-tree callers to tell which version of
the libxc interface this version of xenctrl.h provides.

Signed-off-by: Ian Jackson <ian.jackson@eu.citrix.com>
Acked-by: Ian Campbell <Ian.Campbell@eu.citrix.com>
Committed-by: Ian Jackson <ian.jackson@eu.citrix.com>
tools/libxc/xenctrl.h

index 00c6f4425ec3ba5b683506e17cb232809c52f764..971daf02bc4fd443963be8eb2d24c2e6fcd4460a 100644 (file)
 #endif
 
 
+#define XENCTRL_HAS_XC_INTERFACE 1
+/* In Xen 4.0 and earlier, xc_interface_open and xc_evtchn_open would
+ * both return ints being the file descriptor.  In 4.1 and later, they
+ * return an xc_interface* and xc_evtchn*, respectively - ie, a
+ * pointer to an opaque struct.  This #define is provided in 4.1 and
+ * later, allowing out-of-tree callers to more easily distinguish
+ * between, and be compatible with, both versions.
+ */
+
+
 /*
  *  GENERAL
  *